package expert.dao;


import java.util.List;

import javax.annotation.Resource;

import org.junit.Test;
import org.junit.runner.RunWith;
import org.springframework.test.context.ContextConfiguration;
import org.springframework.test.context.junit4.SpringJUnit4ClassRunner;
import org.springframework.transaction.annotation.Transactional;

import com.chlitina.hq.modules.expert.entity.StoreProduct;
import com.chlitina.hq.modules.expert.service.StoreProductService;

@RunWith(SpringJUnit4ClassRunner.class)
@ContextConfiguration(locations = "classpath:applicationContext.xml")
@Transactional
public class StoreProductTest{
	@Resource
    private StoreProductService storeProductService;
	
    @Test 
    public void saveTest() {
    	List<StoreProduct> list = storeProductService.findByName("EPO");
    	System.out.print(list.size());
    	for (StoreProduct storeProduct : list) {
    		System.out.println(storeProduct.getId());
		}
    }
}
